package cn.lhq.controller.activity;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import cn.lhq.bean.VoteResult;
import cn.lhq.service.ActivityServiceImpl;

@Controller
@RequestMapping("/activity")
public class DeleteActivityController {
	@Resource
	private ActivityServiceImpl activityServiceImpl;
	
	@RequestMapping("/deleteActivity.do")
	@ResponseBody
	public VoteResult deleteActivity(int activityId){
		VoteResult result = new VoteResult();
		try {
			result = activityServiceImpl.delete(activityId);
		} catch (Exception e) {
			e.printStackTrace();
		}
		return result;
	}
	
}
